package com.heima.media.controller;

import com.heima.media.service.WmChannelService;
import com.heima.model.common.dtos.ResponseResult;
import com.heima.model.media.pojos.WmChannel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping(value = "/api/v1/wmChannel")
public class WmChannelController {


    @Autowired
    private WmChannelService wmChannelService;

    /**
     * 查询所有
     */

    @GetMapping(value = "/all")
    public ResponseResult all(){
        List<WmChannel> list = wmChannelService.list();
        return ResponseResult.okResult(list);
    }

}
